package com.example.drop.adapter

import android.widget.LinearLayout
import android.widget.TextView
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.example.drop.R
import com.example.drop.entity.DataEntity

class DataAdapter :BaseQuickAdapter<DataEntity,BaseViewHolder>(R.layout.item_datatime) {
    override fun convert(holder: BaseViewHolder, item: DataEntity) {
        val week = holder.getView<TextView>(R.id.data_week)
        val day = holder.getView<TextView>(R.id.data_day)
        val ll = holder.getView<LinearLayout>(R.id.data_ll)
        week.setText(item.week)
        day.setText(item.day)
        if (item.isCheck){
            ll.setBackgroundResource(R.drawable.shape_status_blue)
        }
    }

}